AcquirePersistentObject
TheAcquirePersistentObject
method returns a reference to the part or frame with the specified scripting ID.
ODPersistentObject AcquirePersistentObject ( in ODPersistentObjectID objectID, out ODObjectType objectType);
objectID
- The scripting ID of the desired object.
objectType
- The type of the object returned, either part (
kODPartObject
) or frame (kODFrameObject
).- return value
- A reference to the part or frame with the specified scripting ID.
DISCUSSION
You call this method to obtain a reference to a part or frame, given the ID that identifies it for scripting purposes. This method should be used only for scripting.This method increments the reference count of the returned persistent object. When you have finished using that persistent object, you should call its
Release
method.EXCEPTIONS
kODErrIllegalNullIDInput
- The
objectID
parameter is null.kODErrInvalidPersistentObjectID
- This draft has no persistent object with the specified ID, or the object is of a type that cannot be acquired.
SEE ALSO
TheODObjectType
type (page 903).
TheODPersistentObjectID
type (page 900).
TheODDraft::GetPersistentObjectID
method (page 174).
"Default Object Accessors" on page 421 in OpenDoc Programmer's Guide.
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help